﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;

/// <summary>
/// Summary description for DynamicSellTemplate
/// </summary>
public class DynamicSellTemplate : ITemplate
{

	

	#region ITemplate Members

	public void InstantiateIn(Control container)
	{
		container.Controls.Clear();
		Label l = new Label();
		l.Attributes["name"] = "Label";
		l.Width = 30;
		l.Height = 20;
		l.Attributes["onclick"] = "changeCode(this, event);";
	//	l.Attributes["ondblclick"] = "madeComment(this, event);return false;";
		container.Controls.Add(l);

		HtmlInputText text = new HtmlInputText();
		text.Style["width"] = "15px";
		text.Style["visibility"] = "hidden";
		text.Style["position"] = "absolute";
		text.Attributes["maxlength"] = "1";
		//text.Attributes["onchange"] = "return validateInput(this);";
		text.Attributes["onblur"] = "validateInput(this)";
		container.Controls.Add(text);

		HtmlInputImage image = new HtmlInputImage();
		image.Src = "~/Images/edit.png";

		image.Attributes["onclick"] = "madeComment(this, event);return false;";
		image.Style["visibility"] = "hidden";
		image.Style["position"] = "absolute";
		image.Attributes["title"] = "Click Here To Enter/Edit a Contact Memo Infromation(up to 200 charactes long)";
		image.Alt = "Click Here To Enter/Edit a Contact Memo Infromation(up to 200 charactes long)";
		container.Controls.Add(image);
		

	
 
	}

	#endregion
}
